From 4476d05cf5e8d3880f88ce16649766df67e0791e Mon Sep 17 00:00:00 2001 From: Jan Beulich Date: Fri, 13 Dec 2013 15:06:11 +0100 Subject: [PATCH] x86/p2m: restrict auditing to debug builds ... since iterating through all of a guest's pages may take unduly long. Signed-off-by: Jan Beulich Acked-by: Ian Campbell Reviewed-by: Andrew Cooper Release-acked-by: George Dunlap Acked-by: Tim Deegan --- xen/include/asm-x86/p2m.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/xen/include/asm-x86/p2m.h b/xen/include/asm-x86/p2m.h index 43583b205c..f4e7253da1 100644 --- a/xen/include/asm-x86/p2m.h +++ b/xen/include/asm-x86/p2m.h @@ -600,7 +600,11 @@ int set_p2m_entry(struct p2m_domain *p2m, unsigned long gfn, mfn_t mfn, extern void p2m_pt_init(struct p2m_domain *p2m); /* Debugging and auditing of the P2M code? */ +#ifndef NDEBUG #define P2M_AUDIT 1 +#else +#define P2M_AUDIT 0 +#endif #define P2M_DEBUGGING 0 #if P2M_AUDIT -- 2.30.2